<template>
	<div class="container w-3/4 mt-10">
		<ReservationDetail :data="result?.detail" :loading="loading"></ReservationDetail>
	</div>
</template>

<script setup lang="ts">
import { detail } from '@/apis/graphql';
import { useQuery } from '@vue/apollo-composable';
const route = useRoute();
const { result, loading, refetch } = useQuery(detail, {
	id: route.params.id + '',
});
watch(
	() => route.params,
	() => refetch({ id: route.params.id + '' }),
	{
		immediate: true,
	},
);
</script>

<style scoped></style>
